package net.synck.gcontacts.tools;

import java.util.HashMap;
import java.util.Map;
import java.util.SortedMap;
import java.util.TreeMap;

import com.google.gdata.data.extensions.Email;
import com.google.gdata.data.extensions.Im;
import com.google.gdata.data.extensions.PhoneNumber;
import com.google.gdata.data.extensions.PostalAddress;

public class RelTools {

	private static final Map<String,String> emailRel = new HashMap<String, String>();
	
	static {
		emailRel.put(Email.Rel.GENERAL, "");
		emailRel.put(Email.Rel.HOME, "home");
		emailRel.put(Email.Rel.OTHER, "other");
		emailRel.put(Email.Rel.WORK, "work");		
	}
	
	private static final Map<String,String> phoneRel = new HashMap<String, String>(); 	
	
	static {
		phoneRel.put(PhoneNumber.Rel.GENERAL, "");
		phoneRel.put(PhoneNumber.Rel.HOME, "home");
		phoneRel.put(PhoneNumber.Rel.OTHER, "other");
		phoneRel.put(PhoneNumber.Rel.WORK, "work");		
		phoneRel.put(PhoneNumber.Rel.WORK_FAX, "work fax");
		phoneRel.put(PhoneNumber.Rel.CAR, "car");
		phoneRel.put(PhoneNumber.Rel.FAX, "fax");
		phoneRel.put(PhoneNumber.Rel.HOME_FAX, "home fax");
		phoneRel.put(PhoneNumber.Rel.INTERNAL_EXTENSION, "internal extension");
		phoneRel.put(PhoneNumber.Rel.MOBILE, "mobile");
		phoneRel.put(PhoneNumber.Rel.PAGER, "pager");
		phoneRel.put(PhoneNumber.Rel.SATELLITE, "satellite");		
	}
	
	private static final Map<String,String> imRel = new HashMap<String, String>(); 	
	
	static {		
		imRel.put(Im.Rel.HOME, "home");
		imRel.put(Im.Rel.OTHER, "other");
		imRel.put(Im.Rel.WORK, "work");		
	}
	
	private static final Map<String,String> imProtocol = new HashMap<String, String>(); 	
	
	static {		
		imProtocol.put(Im.Protocol.AIM, "aim");
		imProtocol.put(Im.Protocol.GOOGLE_TALK, "google talk");
		imProtocol.put(Im.Protocol.ICQ, "icq");
		imProtocol.put(Im.Protocol.JABBER, "jabber");
		imProtocol.put(Im.Protocol.MSN, "msn");
		imProtocol.put(Im.Protocol.QQ, "qq");
		imProtocol.put(Im.Protocol.SKYPE, "skype");
		imProtocol.put(Im.Protocol.YAHOO, "yahoo");					
	}

	private static final Map<String,String> postalAddressRel = new HashMap<String, String>(); 	
	
	static {		
		postalAddressRel.put(PostalAddress.Rel.GENERAL, "");
		postalAddressRel.put(PostalAddress.Rel.HOME, "home");
		postalAddressRel.put(PostalAddress.Rel.OTHER, "other");
		postalAddressRel.put(PostalAddress.Rel.WORK, "work");		
	}	
	
	public static Map<String,String> getEmailRel() {
		return emailRel;
	}
	
	public static Map<String,String> getPhoneNumberRel() {
		return phoneRel;
	}
	
	public static Map<String,String> getImRel() {
		return imRel;
	}

	public static Map<String,String> getImProtocol() {
		return imProtocol;
	}
	
	public static Map<String,String> getPostalAddressRel() {
		return postalAddressRel;
	}
	
}
